package com.beifeng.hadoop.hdfs.secondarysort;

import org.apache.hadoop.io.IntWritable;
import org.apache.hadoop.mapreduce.Partitioner;

public class FirstPartitioner extends Partitioner<IntPair, IntWritable> {

	
	public int getPartition(IntPair key, IntWritable value, int numPartitions) {
		
		
		
		return  Math.abs(key.getFirst()*127) % numPartitions ;
	}

	
	
}
